<%= form_for(@user_folder,:html=>{:class=>"form-horizontal"}) do |f| %>
<% if @user_folder.errors.any? %>
<%= render :partial=>'/layouts/errors', :locals=>{:errors=>@user_folder.errors}%>
<% end %>


<div class="form-group">
  <%= f.label "所属小组",:class=>"col-sm-2 control-label" %>
  <div class="col-sm-3">   
      <p class="form-control-static"><%= @user_folder.group_folder.group.name %></p>
      <%= f.hidden_field(:group_id,:value=>@user_folder.group_folder.group_id )%>
  </div>
</div>

<div class="form-group">
  <%= f.label "小组文件夹",:class=>"col-sm-2 control-label" %>
  <div class="col-sm-3">   
      <p class="form-control-static"><%= @user_folder.group_folder.name %></p>
      <%= f.hidden_field(:group_folder_id )%>
  </div>
</div>

<div class="form-group">
  <%= f.label "文件夹名称",:class=>"col-sm-2 control-label" %>
  <div class="col-sm-4">
  <%= f.text_field :name, autofocus: true,:class=>"form-control",:placeholder=>"文件夹名称"%>
  </div>
</div>

<div class="form-group">
  <%= f.label "文件夹编号",:class=>"col-sm-2 control-label" %>
  <div class="col-sm-4">
  <%= f.text_field :serial_no, autofocus: true,:class=>"form-control",:placeholder=>"文件夹编号"%>
  </div>
</div>


<div class="form-group">
  <%= f.label "负责用户",:class=>"col-sm-2 control-label" %>
  <div class="col-sm-3">
    <%= f.select(:member_id, @users.collect {|p| [ p.user.name, p.id ] },{},:class=>"form-control")%>
  </div>
</div>



<div class="form-group">
  <%= f.label "备注",:class=>"col-sm-2 control-label" %>
  <div class="col-sm-4">
    <%= f.text_field :remark, :class=>"form-control",:rows=>3%>
  </div>
</div>


<!-- <div class="form-group">
  <div class="col-sm-offset-2 col-sm-4">
      <label class="checkbox-inline"><%= f.check_box :enabled%>启用</label>
  </div>
</div> -->
  
<div class="form-group">
  <div class="col-sm-offset-2 col-sm-10">
    <button type="submit" class="btn btn-default btn-primary">提 交</button>
  </div>
</div> 
 
<% end %>

